An important function of optical character recognition (OCR) apparatus is that of segmenting a line of characters into individual character images, so that individual characters may be recognized or identified.
Generally, individual characters are successively written along a horizontal line. Successive horizontal lines are written as necessary. Assuming that the characters are read horizontally, the vertical orientation parameter of the OCR process is generally used to find lines on a document, whereas horizontal orientation is generally referred to as segmentation. Segmentation is the process of dividing a horizontal string of characters into separate or discrete characters, i.e. dividing a word into its individual letters. The segmentation process allows the visual image of a scanned character to be binarized and stored as a binary video data pattern which ideally contains only the data associated with the character to be recognized. The data is typically coded as picture elements (PELS) that are either black or white, which respectively represent the presence of a character portion or the presence of background (i.e. the absence of a character portion) at a particular location.
Once the character is recognized, a coded representation (usually a hexadecimal byte) of that character is transmitted to data processing equipment.
In the past, methods for segmenting character images were expensive, complex, slow, and hardware intensive because they were designed to accommodate the most difficult case. As a result, they were not compatible with modern day microprocessors. For instance, an early segmentation technique is shown in U.S. Pat. No. 3,526,876. In this patent, character pitch is determined from pairs of adjacent characters, and the pitch data is used to partition each character space into areas. Each successive area is scanned vertically, and logical tests are made in each area to determine when the character has been completely scanned. Character height and width are logically analyzed to segment the characters. Pitch is used to segment the characters only if no other segmentation point is located.
U.S. Pat. No. 4,045,773 discloses another early segmentation technique that adjusts the segmentation point depending upon whether or not the scanned character is within a character frame. The rows of horizontally extending characters are scanned vertically after the interval of the lines separating the character frames has been provided. The scanned pattern portion is projected and tested for the presence of a logical 1, which represents a dark spot, to determine whether or not the scanned pattern portion is a blank. The start and end points of a character are determined, and the center of the character is calculated using the start and end points. If the character is too small, scanning continues beyond the first start and end points to determine if the character comprises two or more subpatterns, or if it should be rejected as noise. Having calculated the center of the subpattern or character, the location of the center is compared to the location of the character frame. All characters or patterns or subpatterns having a center within the character frame are segmented as a single character pattern.